3.119 \(\int \sin (a+\frac{b}{x^2}) \, dx\)

Optimal. Leaf size=80 \[ \sqrt{2 \pi } \left (-\sqrt{b}\right ) \cos (a) \text{FresnelC}\left (\frac{\sqrt{\frac{2}{\pi }} \sqrt{b}}{x}\right )+\sqrt{2 \pi } \sqrt{b} \sin (a) S\left (\frac{\sqrt{b} \sqrt{\frac{2}{\pi }}}{x}\right )+x \sin \left (a+\frac{b}{x^2}\right ) \]

[Out]

-(Sqrt[b]*Sqrt[2*Pi]*Cos[a]*FresnelC[(Sqrt[b]*Sqrt[2/Pi])/x]) + Sqrt[b]*Sqrt[2*Pi]*FresnelS[(Sqrt[b]*Sqrt[2/Pi
])/x]*Sin[a] + x*Sin[a + b/x^2]

________________________________________________________________________________________

Rubi [A]  time = 0.0577005, antiderivative size = 80, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 5, integrand size = 8, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.625, Rules used = {3359, 3387, 3354, 3352, 3351} \[ \sqrt{2 \pi } \left (-\sqrt{b}\right ) \cos (a) \text{FresnelC}\left (\frac{\sqrt{\frac{2}{\pi }} \sqrt{b}}{x}\right )+\sqrt{2 \pi } \sqrt{b} \sin (a) S\left (\frac{\sqrt{b} \sqrt{\frac{2}{\pi }}}{x}\right )+x \sin \left (a+\frac{b}{x^2}\right ) \]

Antiderivative was successfully verified.

[In]

Int[Sin[a + b/x^2],x]

[Out]

-(Sqrt[b]*Sqrt[2*Pi]*Cos[a]*FresnelC[(Sqrt[b]*Sqrt[2/Pi])/x]) + Sqrt[b]*Sqrt[2*Pi]*FresnelS[(Sqrt[b]*Sqrt[2/Pi
])/x]*Sin[a] + x*Sin[a + b/x^2]

Rule 3359

Int[((a_.) + (b_.)*Sin[(c_.) + (d_.)*((e_.) + (f_.)*(x_))^(n_)])^(p_.), x_Symbol] :> -Dist[f^(-1), Subst[Int[(
a + b*Sin[c + d/x^n])^p/x^2, x], x, 1/(e + f*x)], x] /; FreeQ[{a, b, c, d, e, f}, x] && IGtQ[p, 0] && ILtQ[n,
0] && EqQ[n, -2]

Rule 3387

Int[((e_.)*(x_))^(m_)*Sin[(c_.) + (d_.)*(x_)^(n_)], x_Symbol] :> Simp[((e*x)^(m + 1)*Sin[c + d*x^n])/(e*(m + 1
)), x] - Dist[(d*n)/(e^n*(m + 1)), Int[(e*x)^(m + n)*Cos[c + d*x^n], x], x] /; FreeQ[{c, d, e}, x] && IGtQ[n,
0] && LtQ[m, -1]

Rule 3354

Int[Cos[(c_) + (d_.)*((e_.) + (f_.)*(x_))^2], x_Symbol] :> Dist[Cos[c], Int[Cos[d*(e + f*x)^2], x], x] - Dist[
Sin[c], Int[Sin[d*(e + f*x)^2], x], x] /; FreeQ[{c, d, e, f}, x]

Rule 3352

Int[Cos[(d_.)*((e_.) + (f_.)*(x_))^2], x_Symbol] :> Simp[(Sqrt[Pi/2]*FresnelC[Sqrt[2/Pi]*Rt[d, 2]*(e + f*x)])/
(f*Rt[d, 2]), x] /; FreeQ[{d, e, f}, x]

Rule 3351

Int[Sin[(d_.)*((e_.) + (f_.)*(x_))^2], x_Symbol] :> Simp[(Sqrt[Pi/2]*FresnelS[Sqrt[2/Pi]*Rt[d, 2]*(e + f*x)])/
(f*Rt[d, 2]), x] /; FreeQ[{d, e, f}, x]

Rubi steps

\begin{align*} \int \sin \left (a+\frac{b}{x^2}\right ) \, dx &=-\operatorname{Subst}\left (\int \frac{\sin \left (a+b x^2\right )}{x^2} \, dx,x,\frac{1}{x}\right )\\ &=x \sin \left (a+\frac{b}{x^2}\right )-(2 b) \operatorname{Subst}\left (\int \cos \left (a+b x^2\right ) \, dx,x,\frac{1}{x}\right )\\ &=x \sin \left (a+\frac{b}{x^2}\right )-(2 b \cos (a)) \operatorname{Subst}\left (\int \cos \left (b x^2\right ) \, dx,x,\frac{1}{x}\right )+(2 b \sin (a)) \operatorname{Subst}\left (\int \sin \left (b x^2\right ) \, dx,x,\frac{1}{x}\right )\\ &=-\sqrt{b} \sqrt{2 \pi } \cos (a) C\left (\frac{\sqrt{b} \sqrt{\frac{2}{\pi }}}{x}\right )+\sqrt{b} \sqrt{2 \pi } S\left (\frac{\sqrt{b} \sqrt{\frac{2}{\pi }}}{x}\right ) \sin (a)+x \sin \left (a+\frac{b}{x^2}\right )\\ \end{align*}

Mathematica [A]  time = 0.134061, size = 81, normalized size = 1.01 \[ -\sqrt{2 \pi } \sqrt{b} \left (\cos (a) \text{FresnelC}\left (\frac{\sqrt{\frac{2}{\pi }} \sqrt{b}}{x}\right )-\sin (a) S\left (\frac{\sqrt{b} \sqrt{\frac{2}{\pi }}}{x}\right )\right )+x \sin (a) \cos \left (\frac{b}{x^2}\right )+x \cos (a) \sin \left (\frac{b}{x^2}\right ) \]

Antiderivative was successfully verified.

[In]

Integrate[Sin[a + b/x^2],x]

[Out]

x*Cos[b/x^2]*Sin[a] - Sqrt[b]*Sqrt[2*Pi]*(Cos[a]*FresnelC[(Sqrt[b]*Sqrt[2/Pi])/x] - FresnelS[(Sqrt[b]*Sqrt[2/P
i])/x]*Sin[a]) + x*Cos[a]*Sin[b/x^2]

________________________________________________________________________________________

Maple [A]  time = 0.01, size = 59, normalized size = 0.7 \begin{align*} x\sin \left ( a+{\frac{b}{{x}^{2}}} \right ) -\sqrt{b}\sqrt{2}\sqrt{\pi } \left ( \cos \left ( a \right ){\it FresnelC} \left ({\frac{\sqrt{2}}{\sqrt{\pi }x}\sqrt{b}} \right ) -\sin \left ( a \right ){\it FresnelS} \left ({\frac{\sqrt{2}}{\sqrt{\pi }x}\sqrt{b}} \right ) \right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(a+b/x^2),x)

[Out]

x*sin(a+b/x^2)-b^(1/2)*2^(1/2)*Pi^(1/2)*(cos(a)*FresnelC(b^(1/2)*2^(1/2)/Pi^(1/2)/x)-sin(a)*FresnelS(b^(1/2)*2
^(1/2)/Pi^(1/2)/x))

________________________________________________________________________________________

Maxima [C]  time = 1.41088, size = 539, normalized size = 6.74 \begin{align*} \text{result too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(a+b/x^2),x, algorithm="maxima")

[Out]

1/4*(4*x^2*sqrt(abs(b)/x^2)*sin((a*x^2 + b)/x^2) - (((sqrt(pi)*(erf(sqrt(I*b/x^2)) - 1) + sqrt(pi)*(erf(sqrt(-
I*b/x^2)) - 1))*cos(1/4*pi + 1/2*arctan2(0, b)) + (sqrt(pi)*(erf(sqrt(I*b/x^2)) - 1) + sqrt(pi)*(erf(sqrt(-I*b
/x^2)) - 1))*cos(-1/4*pi + 1/2*arctan2(0, b)) - (I*sqrt(pi)*(erf(sqrt(I*b/x^2)) - 1) - I*sqrt(pi)*(erf(sqrt(-I
*b/x^2)) - 1))*sin(1/4*pi + 1/2*arctan2(0, b)) - (-I*sqrt(pi)*(erf(sqrt(I*b/x^2)) - 1) + I*sqrt(pi)*(erf(sqrt(
-I*b/x^2)) - 1))*sin(-1/4*pi + 1/2*arctan2(0, b)))*cos(a) - ((I*sqrt(pi)*(erf(sqrt(I*b/x^2)) - 1) - I*sqrt(pi)
*(erf(sqrt(-I*b/x^2)) - 1))*cos(1/4*pi + 1/2*arctan2(0, b)) + (I*sqrt(pi)*(erf(sqrt(I*b/x^2)) - 1) - I*sqrt(pi
)*(erf(sqrt(-I*b/x^2)) - 1))*cos(-1/4*pi + 1/2*arctan2(0, b)) + (sqrt(pi)*(erf(sqrt(I*b/x^2)) - 1) + sqrt(pi)*
(erf(sqrt(-I*b/x^2)) - 1))*sin(1/4*pi + 1/2*arctan2(0, b)) - (sqrt(pi)*(erf(sqrt(I*b/x^2)) - 1) + sqrt(pi)*(er
f(sqrt(-I*b/x^2)) - 1))*sin(-1/4*pi + 1/2*arctan2(0, b)))*sin(a))*b)/(x*sqrt(abs(b)/x^2))

________________________________________________________________________________________

Fricas [A]  time = 1.72826, size = 209, normalized size = 2.61 \begin{align*} -\sqrt{2} \pi \sqrt{\frac{b}{\pi }} \cos \left (a\right ) \operatorname{C}\left (\frac{\sqrt{2} \sqrt{\frac{b}{\pi }}}{x}\right ) + \sqrt{2} \pi \sqrt{\frac{b}{\pi }} \operatorname{S}\left (\frac{\sqrt{2} \sqrt{\frac{b}{\pi }}}{x}\right ) \sin \left (a\right ) + x \sin \left (\frac{a x^{2} + b}{x^{2}}\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(a+b/x^2),x, algorithm="fricas")

[Out]

-sqrt(2)*pi*sqrt(b/pi)*cos(a)*fresnel_cos(sqrt(2)*sqrt(b/pi)/x) + sqrt(2)*pi*sqrt(b/pi)*fresnel_sin(sqrt(2)*sq
rt(b/pi)/x)*sin(a) + x*sin((a*x^2 + b)/x^2)

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \sin{\left (a + \frac{b}{x^{2}} \right )}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(a+b/x**2),x)

[Out]

Integral(sin(a + b/x**2), x)

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \sin \left (a + \frac{b}{x^{2}}\right )\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(a+b/x^2),x, algorithm="giac")

[Out]

integrate(sin(a + b/x^2), x)